package com.polarrose.spring.bayeux;

import java.io.Serializable;

public class BayeuxDestination implements Serializable
{
    /**
     * The name of the destination.
     */

    private String name;

    public String getName()
    {
        return name;
    }

    public void setName(String name)
    {
        this.name = name;
    }

    public BayeuxDestination()
    {
    }

    public BayeuxDestination(String name)
    {
        this.name = name;
    }

    @Override
    public String toString()
    {
        return "BayeuxDestination[name=" + name + "]";
    }

    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        BayeuxDestination that = (BayeuxDestination) o;

        if (name != null ? !name.equals(that.name) : that.name != null) return false;

        return true;
    }

    public int hashCode() {
        return (name != null ? name.hashCode() : 0);
    }
}
